RobotCaleb 0 Posted September 23, 2014 Share Posted September 23, 2014 Hi, if this is the wrong forum please direct me elsewhere. I have an AS5048A chip that I've successfully pulled data from using an Arduino board. Datasheet for AS5048A - http://www.ams.com/eng/content/download/438523/1341157/file/AS5048_Datasheet.pdf I finally pulled my LM4F120 eval kit that I got last year out and started playing with it. I'm not having any success reading data from the chip with it, though. My embedded experience is limited to the higher level abstractions of Arduino stuff and I occasionally feel like I'm just flapping my arms uselessly. I will say that being able to step through my code running on the LM4F120 (is that the proper way to describe it?) is totally pleasurable and super handy. At any rate, my issues: First, here's the code that should successfully grab the data with an Arduino board. At least, an equivalent was until mine stopped allowing me to upload to it. http://pastebin.com/aXGvkXiw The chip says I can interface in 4-wire or 3-wire mode. 3-wire being read only. (Page 13 of the datasheet) I've tried enabling GPIO port A, enabling SSI, configuring the 3 pins for RX, CLK, and SS. When in this mode whenever I call GPIOPinTypeSSI PA3 (SS) goes high and I can't write it low with GPIOPinWrite(). I realize that's probably the wrong way to do it, but I don't know enough yet to know better. I've also tried enabling GPIO port A, enabling SSI, configuring RX and CLK for SSI, and configuring PA3 for GPIOPinTypeGPIOOutput thinking I need to set it to low then high manually (as the datasheet and the Arduino code show). I should point out that this feels entirely wrong. Relevant code: http://pastebin.com/9GhjLwk8 I've also tried compiling and running the equivalent Arduino code in Energia. All to no avail. I'd appreciate any pointers, pointing out of errors, or even a working example for interfacing with this chip. I wasn't expecting to run into this so early into my project. Quote Link to post Share on other sites
RobotCaleb 0 Posted September 23, 2014 Author Share Posted September 23, 2014 Oh, I also have a couple AS5048B chips, which speak I2C, I believe. Not sure if that'd be any easier, as I've never used it. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.