|
Ok this is weird. Apparently something went haywire because now when I point it north it still says west. The exact degree readings are coming still but what the gently caress.
|
# ? May 16, 2018 04:43 |
|
|
# ? Mar 29, 2024 10:20 |
What accuracy are you shooting for? Intracardinal is not too bad to obtain with good repeatability. Low double digits starts to need some compensation algorithms. Single digits will require active hard iron/soft iron compensations. Under 1 degree requires advanced degrees in math and algorithms. E: ^^^^ things that aren't magnets can gently caress up the readings. Cell phones are veritable fountains of magnetic interference. A bolt in your desk under laminate can cause issues like this. It doesn't take much. carticket fucked around with this message at 05:48 on May 16, 2018 |
|
# ? May 16, 2018 05:42 |
|
Mr. Powers posted:What accuracy are you shooting for? Intracardinal is not too bad to obtain with good repeatability. Low double digits starts to need some compensation algorithms. Single digits will require active hard iron/soft iron compensations. Under 1 degree requires advanced degrees in math and algorithms. I'm not talking a few degrees off here. I'm talking when I point it north it still says west, even if I turn it eastwards first.
|
# ? May 16, 2018 13:59 |
No, I get that. You'd be surprised how little it takes to throw the math off a large amount. Particularly if you don't have anything in place for compensations.
|
|
# ? May 16, 2018 22:40 |
|
I just found out TI has some pretty nifty ULP MCUs with decent-sized on-chip FRAM, and they are about 30% cheaper than any equivalent-sized FRAM chips I can find. I also found out that they have yet another eclipse-based IDE. I think I have about 6 of them installed at this point, including actual non-brand eclipse. I've been using it for about 12 years now though, so I actually prefer it over just about everything else. e: It's not like there's a whole lot of IDEs around anyway Private Speech fucked around with this message at 19:44 on May 25, 2018 |
# ? May 25, 2018 19:35 |
|
Private Speech posted:I just found out TI has some pretty nifty ULP MCUs with decent-sized on-chip FRAM, and they are about 30% cheaper than any equivalent-sized FRAM chips I can find. The MSP430FRs? I've been using them and I like them. quote:I also found out that they have yet another eclipse-based IDE. Personally I hate Eclipse for editing so I do my coding elsewhere and use CCS to build / debug. In fairness I really like the stack usage and memory allocation graphs, and it has a live power consumption monitor during debugging sessions which is pretty neat.
|
# ? May 26, 2018 17:04 |
|
csammis posted:The MSP430FRs? I've been using them and I like them. Yeah, those. Specifically the 256KB versions; it replaces a more expensive component, is ULP so power is not a huge issue and you get a whole MCU essentially for free.
|
# ? May 27, 2018 22:57 |
|
Private Speech posted:Yeah, those. Specifically the 256KB versions; it replaces a more expensive component, is ULP so power is not a huge issue and you get a whole MCU essentially for free. Why would you want to add programmable parts...
|
# ? May 28, 2018 15:43 |
|
I'm working on an Arduino thing for work and I'm trying to make use of Structs to make things a little easier. Problem is, I don't know a lot about them! I also am a little fuzzy on pointers and referencing, so as you can imagine, this is tough for me. So, I want to be a be able to pass a struct into a function and have it modify the data in the struct, either directly or returning the info. What's the best way to do that? I have something along these lines: code:
code:
|
# ? May 28, 2018 16:25 |
Of course you would have to reference State and Score as members of the struct but you have the general idea right. Always pass a pointer to a struct.
|
|
# ? May 28, 2018 16:45 |
|
ah yeah forgot to do the membering there. And I wouldn't have to do a return, correct? Because this manipulating the original data, rather than passing a copy.
|
# ? May 28, 2018 16:59 |
|
Fanged Lawn Wormy posted:ah yeah forgot to do the membering there. Yes you are manipulating the original data. No need for return (you could return an error code to tell the caller if you succeeded though). If you would have your method signature like this: code:
|
# ? May 28, 2018 17:07 |
|
There are a bunch of online compilers that are really good for this if you just want to test some C code quickly. Especially if you want to do some complicated pointer stuff that might corrupt real hardware in non obvious ways that are difficult to debug.
|
# ? May 28, 2018 18:01 |
|
|
# ? Mar 29, 2024 10:20 |
|
Phobeste posted:Why would you want to add programmable parts... The joke answer is that I get paid to write programs, not to design simple things. The real answer is we needed an SoC of some kind anyway, and the higher-tier FRs have GPIOs aplenty. (also TI has a dead-easy sample project for turning the MCU into an SPI-FRAM-with-altogether-too-many-pins; not that I can use it anyway because I need more complex functionality)
|
# ? Jun 1, 2018 19:17 |