To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.roboticsOpen lugnet.robotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / 26474
26473  |  26475
Subject: 
Re: NXT direct commands
Newsgroups: 
lugnet.robotics
Date: 
Tue, 3 Oct 2006 16:54:27 GMT
Viewed: 
3078 times
  
For better documentation of the various parameters, look in the
Executable File Specification.pdf around page 81.  Here's the notes I
made in ruby-nxt (http://rubyforge.org/projects/ruby-nxt/):

  # output mode
  COAST     = 0x00 # motor will rotate freely?
  MOTORON   = 0x01 # enables PWM power according to speed
  BRAKE     = 0x02 # voltage is not allowed to float between PWM
pulses, improves accuracy, uses more power
  REGULATED = 0x04 # required in conjunction with output regulation mode setting

  # output regulation mode
  REGULATION_MODE_IDLE        = 0x00 # disables regulation
  REGULATION_MODE_MOTOR_SPEED = 0x01 # auto adjust PWM duty cycle if
motor is affected by physical load
  REGULATION_MODE_MOTOR_SYNC  = 0x02 # attempt to keep rotation in
sync with another motor that has this set, also involves turn ratio

  # output run state
  MOTOR_RUN_STATE_IDLE        = 0x00 # disables power to motor
  MOTOR_RUN_STATE_RAMPUP      = 0x10 # ramping to a new SPEED
set-point that is greater than the current SPEED set-point
  MOTOR_RUN_STATE_RUNNING     = 0x20 # enables power to motor
  MOTOR_RUN_STATE_RAMPDOWN    = 0x40 # ramping to a new SPEED
set-point that is less than the current SPEED set-point

  # sensor mode
  RAWMODE             = 0x00 # report scaled value equal to raw value
  BOOLEANMODE         = 0x20 # report scaled value as 1 true or 0
false, false if raw value > 55% of total range, true if < 45%
  TRANSITIONCNTMODE   = 0x40 # report scaled value as number of
transitions between true and false
  PERIODCOUNTERMODE   = 0x60 # report scaled value as number of
transitions from false to true, then back to false
  PCTFULLSCALEMODE    = 0x80 # report scaled value as % of full scale
reading for configured sensor type
  CELSIUSMODE         = 0xA0
  FAHRENHEITMODE      = 0xC0
  ANGLESTEPSMODE      = 0xE0 # report scaled value as count of ticks
on RCX-style rotation sensor
  SLOPEMASK           = 0x1F
  MODEMASK            = 0xE0

On 10/3/06, Nether <lego-robotics@crynwr.com> wrote:
Hi, i'm programing a Python library for remote controlling the NXT, now i'm
working with the "set output state" message and i would like to know what
means the diferent values of each parameter:

#MOTOR MODES
MOTORON = 0x01
BRAKE = 0x02
REGULATED = 0x04

#MOTOR REGULATION MODES
REGULATION_IDLE = 0x00
REGULATION_MOTOR_SPEED = 0x01
REGULATION_MOTOR_SYNC = 0x02

#RUN STATES
RUN_STATE_IDLE = 0x00
RUN_STATE_RAMPUP = 0x10
RUN_STATE_RUNNING = 0x20
RUN_STATE_RAMPDOWN = 0x40

I have tried to send them to the NXT to discover what they do, but the
behavior isn't what i expect.
--
View this message in context: http://www.nabble.com/NXT-direct-commands-tf2377311.html#a6623948
Sent from the LEGO Robotics mailing list archive at Nabble.com.




Message is in Reply To:
  NXT direct commands
 
Hi, i'm programing a Python library for remote controlling the NXT, now i'm working with the "set output state" message and i would like to know what means the diferent values of each parameter: #MOTOR MODES MOTORON = 0x01 BRAKE = 0x02 REGULATED = (...) (18 years ago, 3-Oct-06, to lugnet.robotics)

2 Messages in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    
Active threads in Robotics

 
Verified and Trusted Team of Hackers
2 hours ago
Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR