hominoids / SBC_Case_Builder

Autonomous SBC case generation using SBC Model Framework
GNU General Public License v3.0
370 stars 23 forks source link

access_port rotation bug #26

Closed amazingfate closed 1 year ago

amazingfate commented 1 year ago

I want to rotate the access_port 180 degree for my rock5b v1.3 board, here is my attempt:

diff --git a/sbc_case_builder_accessories.cfg b/sbc_case_builder_accessories.cfg
index 4708fee..2a8ed19 100644
--- a/sbc_case_builder_accessories.cfg
+++ b/sbc_case_builder_accessories.cfg
@@ -1354,7 +1354,7 @@ accessory_data = [
              "sub","rectangle",-1,66.5,13,"top",[0,0,0],["sbc",true,true,false],10,2,8,0,0,"",[.25,.25,.25,.25],                        // UL standoff adjustment
              "sub","rectangle",92,17.5,13,"top",[0,0,0],["sbc",true,true,false],10,2,15,0,0,"",[.25,.25,.25,.25],                        // LR standoff adjustment
              "sub","rectangle",77,67,-1,"bottom",[0,0,0],["sbc",true,true,false],15,18,12.5,0,0,"",[.25,.25,.25,.25],                   // sdcard opening
-             "add1","access_port",10,0,-0.01,"bottom",[0,0,0],["sbc",true,true,false],80,75,2,0,0,"portrait",0,                         // access port
+             "add1","access_port",90,10,-0.01,"bottom",[0,0,180],["sbc",true,true,false],80,75,2,0,0,"portrait",0,
 // access port
              "model","access_cover",10,0,-0.01,"bottom",[0,0,0],["sbc",true,true,false],80,75,2,0,0,"portrait",0,                       // model access port cover
              "platter","access_cover",-110,30,0,"bottom",[0,0,0],["case",false,false,false],80,75,2,0,0,"portrait",0],                  // platter access port cover

Here is what I get: image

hominoids commented 1 year ago

Thanks for reporting the issue, I'll take a look.

hominoids commented 1 year ago

Give it a try now from the main branch, it should work for 180 degree rotation in landscape or portrait. This accessory wasn’t originally designed to be rotated but this fix should work until I get to the planned improvements in this area.

FYI, The Rock5b SBC model is not verified yet and I suspect it needs some adjustments. Unfortunately I don’t own one but I briefly worked with another Radxa user to build the current Rock5b model in SBC Model Framework but it was never verified. I see your active on the Radxa forum so I’ll ask if you would be willing to help verify the rock5b model?

It simply means that a case for the Rock5b would need to be 3D printed from SBC Case Builder, it could be the one your working on now. If the case is misaligned then changes are made to adjust the virtual model in sbc_models.cfg so that it matches the real SBC, using the printed case as a guide. Once the Rock5b fits the printed case the model is correctly aligned and is verified. All subsequent designs will then print correctly for the Rock5b within SBC Case Builder.

If your willing to give it a try let me know I can help as well. What you would get out of it are correctly fitted Rock5b cases for yourself and the Radxa community.

amazingfate commented 1 year ago

@hominoids Thank you for your quick fix! I have a rock5b v1.3 board which has something different compared with the public releasd v1.42 board. Here are the top and bottom photo of it: image image Since I don't have a printer,I'm going to print a case using your builder for it by the 3D print service of JLC China. By the way I know my friend @happyme531 has printed a case using your builder for rock5b, he may help you about it. I will modify these following things to make the case fit for my rock5b v1.3 board: 1, rotate the access_port so that it fits with the bottom emmc and m.2 location 2, change the fan connector location and add openings for it on the case I will follow the other locations from your code. I will feedback infos when I get my case. Here is what I've done: image

hominoids commented 1 year ago

Thanks for the clarification regarding the different models. It sounds like multiple SBC Model Framework entries should be created, one for each version of the board. If your willing to share your v1.3 changes when finished, I'll create a new SBC, rock5b-v1.3 or accept a pull request for SBC Model Framework. Any help by you or anyone else to get working rock5b models for v1.3, v1.42 or whatever the production version is, would be appreciated. I see Radxa just released a Rock5a too.