cs3720

 

Prototyping

Page history last edited by David Sharpe 1 yr ago

A resource page for any prototyping being done:

 

  • Early GUI prototype files: link
  • Tutorial on using VB to connect to the robot: link

 

Comments:

 


Added a link to the .vb files that were used to generate the prototype images that were included in our design document. Warning: the program is not very functional and I did not follow any coding conventions (ie: it was definetely a hack job) but perhaps the layout or design may be a useful starting point. ~bpeake

 

Nice find! After reading it over I'm glad we chose VB for this =p Should be pretty easy once we nail the specifics with the robot team ~Dave F


 

Added a link to a website that has a couple tutorials on how to use VB to connect to an NXT machine (It includes a tutorial on setting up the serial port, getting information from the NXT and sending information to the NXT) ~bpeake


 

I'm still fooling around with direct commands, and I made some useful progress today:

 

 

Everything you see works except the "Backward" button. I think I know how to make it move backwards, but I'm having trouble implementing it. I have one byte that I set in the message that is related to speed. Its valid values are -100 to 100. For Left, Right, and Forward, I have that byte set to &H50, the hex for decimal 80. To move backwards, I think I simply need to change that to a negative value, but how do I write negative values in VB's hex code?

 

e.g.

Dim byteOut(15) As Byte

byteOut(5) = &H50

 

~DS

 


 

 

Woot! Forwards, backwards, this baby does it all.

Point of interest:

  1. &H50 = 80 = 01010000
  2. 2's complement of 01010000 = 10101111 + 1 = 10110000
  3. 10110000 = -80 in 2's complement
  4. 10110000 = &HB0

 

It's not the most impressive "active control" in the world, but it works.

 

~DS

 


 

I'm trying to make my prototype fit the coding conventions. I'll post a link to the .VB file when I'm done so that Brett can run it through Doxygen.

 

~DS

Comments (0)

You don't have permission to comment on this page.