|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
Dashboard Programming
I was just wondering if anyone knows what the 6 user bytes and the user warning, error and command bytes are for. I've looked around and I haven't been able to figure out what they're used for. If anyone knows what they're for, I'd really appreciate the help.
BTW, I'm new to these forums so I hope I'm posting this in the right place. |
|
#2
|
|||||
|
|||||
|
Re: Dashboard Programming
The 6 user bytes can be set in the program to be fed back to the Operator Interface. The first user byte (default p1_y) can be viewed on the OI by switching it to user mode. I don't know any of the details about the error, or warning, or USER CMD bytes.
Welcome to the forums! Programming is a good place to put a question like this. It also could be put in the Control System Section. |
|
#3
|
||||
|
||||
|
Re: Dashboard Programming
Thanks for the information! I'll be sure to go over the FRC source code to make sure to find out what exactly is being sent back in those user bytes.
|
|
#4
|
|||||
|
|||||
|
Re: Dashboard Programming
The USER_BYTEs are viewable via the IFI provided dashboard program on a PC connected to the OI via the dashboard port.
|
|
#5
|
||||
|
||||
|
Re: Dashboard Programming
I was going to put this in a new thread, but is discussed a little here. Could someone explain how to use the 6 user bytes please(without messing up my pwm outputs)?
|
|
#6
|
||||
|
||||
|
Re: Dashboard Programming
Quote:
For example, if you want a user byte to show the analog pressure switch, something like this would work... user_byte1 = analog_pressure; Of course, the analog inputs are 10 bits, instead of 8 bits, so that screws you up, and I haven't found a good way to get around that yet... :-\ |
|
#7
|
|||||
|
|||||
|
Re: Dashboard Programming
Quote:
(make sure you have ifi_aliases.h included) [edit]Each of these User_Byte1,2,3,4,5,6 are defined in ifi_aliases.h and are all "unsigned char" Code:
User_Byte1 = LeftAmps;
User_Byte2 = RightAmps;
/* Display the gyro heading byte3 if its negative, byte4 if its positive */
igyrovalue = Gyro_Degrees();
if (igyrovalue > 0)
{
User_Byte3 = 0;
User_Byte4 = (char) igyrovalue;
}
else
{
User_Byte3 = (char) -igyrovalue;
User_Byte4 = 0;
}
User_Byte5 = 99; // Displays "99" on the dashboard program
User_Byte6 = 254; // No particular reason
Last edited by Mark McLeod : 11-03-2004 at 08:48. |
|
#8
|
|||||
|
|||||
|
Re: Dashboard Programming
Also, user bytes 1 & 2 need ".allbits" They're special. Check ifi_default.h
|
|
#9
|
||||
|
||||
|
Re: Dashboard Programming
Thanks! I'll probably be using this to write some debug code.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| New dashboard packet spec | Ameya | Programming | 2 | 08-01-2004 19:59 |
| Dashboard Decoder Release Version 1.0 Now Available! | archiver | 2000 | 1 | 23-06-2002 22:50 |
| New Innovation FIRST control system and the dashboard | archiver | 2000 | 0 | 23-06-2002 22:15 |
| pbasic programming | punarhero | Programming | 4 | 21-01-2002 23:32 |
| Dashboard Viewer | Khalicl13 | Technical Discussion | 8 | 15-06-2001 23:36 |