HelTecAutomation / platform-asrmicro650x

ASR Microelectronics ASR650x: development platform for PlatformIO
https://registry.platformio.org/platforms/heltecautomation/asrmicro650x
24 stars 15 forks source link

Documentation incorrectly lists ASR6501 as microcontroller for newer ASR6502 based products #1

Closed lnlp closed 4 years ago

lnlp commented 4 years ago

According to product descriptions on Heltec site the microcontroller for the newer '02' series products is ASR6502,

PlatformIO documentation (platform and boards documentation) incorrectly lists ASR6501 as microcontroller for these newer '02' series products.

valeros commented 4 years ago

Hi @lnlp ! Could you please point out what boards are based on ASR6502 ? I didn't see any mention of ASR6502 in the Arduino framework. Thanks!

lnlp commented 4 years ago

Hi @valeros, With all respect and no pun intended, but I'm flabbergasted by that question. For writing technical (PlatformIO) documentation (and maintaining repositories) for products, one would at least expect substantive knowledge about those products and familiarity with existing product documentation. How otherwise can the results ever be relied upon? I suggest you contact Heltec / @Heltec-Aaron-Lee for details about Heltec products.

For public CubeCell product information and documentation you may check:

Update: Above response was based on assumption that you are from Heltec (because Heltec repository) while you appear to be from PlatformIO instead. It will help to make that clear from the start.

valeros commented 4 years ago

@lnlp Thanks for your remarks. It's not a major release of the platform so there might be some inaccuracies and since PlatformIO documentation is generated automatically based on the board manifests these inaccuracies may unintentionally slip to the docs. For example, let's take a look at CubeCell Capsule Solar Sensor product page. In the overview, it's mentioned as ASR6052-based board, but in the tech specs ASR6501 is listed as the LoRa chip. These mistakes don't affect the build process as the ASR6501 is hardcoded as the main chip for all boards.

Anyway, thanks for pointing this out.

lnlp commented 4 years ago

Okay clear, so most of the PlatformIO docs is auto generated. It still should be correct though.

What I miss (at least in/I only checked the preprocessor section) are definitions like -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch}. (Maybe they are not required in the preprocessor phase here but at least it's defined in the ArduinoAVR core). Not that this would make a difference for the issue at hand because the architecture is (or at least should be) 'ASR650x' (or 'ASR6500') which currently serves both ASR6501 and ASR6502.

In the overview, it's mentioned as ASR6052-based board, but in the tech specs ASR6501 is listed as the LoRa chip.

Those and other errors should be corrected as well.

the ASR6501 is hardcoded as the main chip for all boards

That probably has to do with certain compiler features that work for both ASR6501 and ASR6502 which are not effected by how many, which and what type of GPIO ports are actually available on a device etc. If there would only be ASR6501 there would be no (mentioning of) ASR6502 at all.

What's not making things more clear in naming is that the ASR6501 and ASR6502 chips are actually SiP's that combine both a Cypress PSoC 4000 ARM Cortex microcontroller with Semtech SX1262 LoRa tranceiver. But for reference purposes it is sufficient to mention ASR6501 and ASR6502, because that is what these chips are after all.

In certain places where the compiler/preprocessor symbols '6501' or 'ASR6501' are specified this may be the result of poor naming (in which case ASR6500 or ASR650x would have been more appropriate). But such compiler/preprocessor options are (as shown) not representative for the actual ASR6501 or ASR6502 chip being used and should not lead to incorrect documentation.

There also should exist an identifier which identifies the actual chip (ASR6501 or ASR6502) for which the code is compiled. Because you want to be able to check that as a dependency in (application) code.

valeros commented 4 years ago

What I miss (at least in/I only checked the preprocessor section) are definitions like -DARDUINO_{build.board} -DARDUINOARCH{build.arch}. Not that this would make a difference for the issue at hand because the architecture is (or at least should be) 'ASR650x' (or 'ASR6500') which currently serves both ASR6501 and ASR6502.

Arduino core for ASR650x is an open source project, if you do see that something is missing in the docs/framework/etc why don't you provide a PR? I'm sure the maintainers will greatly appreciate your contribution.

In certain places where the compiler/preprocessor symbols '6501' or 'ASR6501' are specified this may be the result of poor naming (in which case ASR6500 or ASR650x would have been more appropriate). But such compiler/preprocessor options are (as shown) not representative for the actual ASR6501 or ASR6502 chip being used and should not lead to incorrect documentation.

There also should exist an identifier which identifies the actual chip (ASR6501 or ASR6502) for which the code is compiled. Because you want to be able to check that as a dependency in (application) code.

We simply strive to reproduce the same build environment specified in the platform.txt file for each platform supported by PlatformIO with no or minimal intrusion from our side that might be caused by differences in the internal build systems. We have no accurate view or sound reasoning behind the decision to hardcode ASR6501 chip in the platform.txt file. This probably will be fixed in the next relase of Arduino core for ASR650x.

lnlp commented 4 years ago

if you do see that something is missing in the docs/framework/etc why don't you provide a PR

This was just a quick observation based on the link you provided.

lnlp commented 4 years ago

Hi @valeros In my first response ("I'm flabbergasted") I was assuming that you are from/related to Heltec (because Heltec repository) hence my surprise about asking me for Heltec product information. I just noticed that you are from/related to PlatformIO instead which makes things more clear. If that would have been made clear from the start that would have helped streamline the communication and my response would have been different.

Is this repository maintained/managed by Heltec or by PlatformIO?

lnlp commented 4 years ago

@valeros @ivankravets This issue has been closed but it has not been fixed and should therefore be re-opened again.

valeros commented 4 years ago

Doc pages for this platform has been updated https://docs.platformio.org/en/latest/boards/index.html#asr-microelectronics-asr605x

lnlp commented 4 years ago

Thanks. My bad. I checked (several pages) but still saw the old information. This appeared to be caused by browser cache. Forcing refresh-all fixed it and shows the updated information.

lnlp commented 4 years ago

I cleared my browser cache but the following pages still list ASR6501 as MCU for all boards:

https://platformio.org/platforms/asrmicro650x https://platformio.org/boards (enter CubeCell as board name)

Further: search on MCU finds ASR6501 boards only, none ASR6502.

valeros commented 4 years ago

Thanks, the platform registry is now updated as well.

juanjole commented 2 years ago

Hello, regarding this issue, I think the Heltec CubeCell Capsule Solar Sensor is not well defined and the microcontroller is the ASR6501.

In addition, I am working with this device and I had to hardcode 'asr6501' in the 'mcu' field of my environment to make it work because if not there is a compilation error.

I hope you can fix it in the code and official documentation of PlatformIO. Thanks.