energia / Energia

Fork of Arduino for the Texas Instruments LaunchPad's
http://energia.nu
Other
794 stars 672 forks source link

IRremote library uses timer A1 - add option to user timer A0 #118

Open kabturek opened 12 years ago

kabturek commented 12 years ago

I'm not sure if thats documented somewhere but the IRremote library expects a timer1 and won't work with board other than msp430g2553. I know that serial uses timer0 but serial isn't always used so an optional define would be great.

It's defined in IRRemoteInt.h https://github.com/energia/Energia/blob/master/hardware/msp430/libraries/IRremote/IRremoteInt.h#L149

robertinant commented 12 years ago

@kabturek thanks for the suggestion. I think we can do a selection based on the MCU being compiled for. If A1 is available then IR should use A1 otherwise it should use A0. Conflict with Serial is a potential issue but I guess that is just as much of an issue with any other lib that uses A0/A1. Do you happen to already have a patch?