Skip to content

Commit 2a157de

Browse files
CopilotELMOURABEA
andcommitted
Implement UAE Commemorative Coin QR code generation system
Co-authored-by: ELMOURABEA <189882272+ELMOURABEA@users.noreply.github.com>
1 parent 4e3ebb6 commit 2a157de

20 files changed

Lines changed: 1693 additions & 0 deletions

β€Ž2README.mdβ€Ž

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,36 @@ activbot:
130130
- Automated testing on every push
131131
- Plugin and workflow compatibility checking
132132
133+
## UAE Commemorative Coin Project
134+
135+
This repository includes a QR code generation system for the UAE Commemorative Coin Project. The system generates QR codes linking to emirate-specific pages, cultural content, and project resources.
136+
137+
### Quick Access QR Codes
138+
139+
<table>
140+
<tr>
141+
<td align="center">
142+
<img src="uae_coin_project/qr_codes/emirate1_abudhabi_qr.png" width="120"><br>
143+
<b>Abu Dhabi</b>
144+
</td>
145+
<td align="center">
146+
<img src="uae_coin_project/qr_codes/emirate2_dubai_qr.png" width="120"><br>
147+
<b>Dubai</b>
148+
</td>
149+
<td align="center">
150+
<img src="uae_coin_project/qr_codes/falcon_eye_culture_qr.png" width="120"><br>
151+
<b>Culture</b>
152+
</td>
153+
</tr>
154+
</table>
155+
156+
### Resources
157+
158+
- πŸ“± [QR Code Generator](uae_coin_project/generate_qr_codes.py)
159+
- πŸ“– [UAE Coin Project Documentation](uae_coin_project/README.md)
160+
- πŸ”„ [QR Update Instructions](uae_coin_project/docs/UPDATE_QR_DESTINATIONS.md)
161+
- πŸ“‹ [Integration Examples](uae_coin_project/docs/INTEGRATION_EXAMPLES.md)
162+
133163
## Contributing
134164
135165
Contributions are welcome! Please:

β€Žrequirements.txtβ€Ž

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
pyyaml>=6.0
33
jsonschema>=4.17.0
44

5+
# QR code generation for UAE Commemorative Coin Project
6+
qrcode>=7.4.2
7+
pillow>=10.3.0
8+
59
# Testing dependencies (dev)
610
pytest>=7.4.0
711
pytest-cov>=4.1.0

β€Žuae_coin_project/README.mdβ€Ž

Lines changed: 240 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,240 @@
1+
# UAE Commemorative Coin Project - QR Code System
2+
3+
This directory contains the QR code generation system for the UAE Commemorative Coin Project. The system generates QR codes that link to emirate-specific pages, cultural content, project documentation, and downloadable assets.
4+
5+
## 🎯 Purpose
6+
7+
Generate QR codes for embedding in:
8+
- Formal documents
9+
- Project web pages
10+
- Commemorative coins (physical or digital)
11+
- Marketing materials
12+
- Documentation
13+
14+
## πŸ“± QR Code Destinations
15+
16+
### Live at Minting
17+
1. **Emirate 1 (Abu Dhabi)** - `https://u.ae/abudhabi`
18+
2. **Emirate 2 (Dubai)** - `https://u.ae/dubai`
19+
3. **Falcon Eye (Culture)** - `https://u.ae/culture`
20+
21+
### Project Resources
22+
4. **Project Web Page** - GitHub repository
23+
5. **Documentation** - Technical documentation
24+
6. **Downloadable 3D Model** - Release assets
25+
26+
## πŸš€ Quick Start
27+
28+
### Prerequisites
29+
30+
```bash
31+
# Install required dependencies
32+
pip install qrcode[pil] pillow>=10.3.0
33+
```
34+
35+
### Generate QR Codes
36+
37+
```bash
38+
# Navigate to the project directory
39+
cd uae_coin_project
40+
41+
# Run the QR code generator
42+
python generate_qr_codes.py
43+
```
44+
45+
### Output
46+
47+
The script generates:
48+
- **PNG files** - High-quality raster images for documents and print
49+
- **SVG files** - Vector images for web and scalable applications
50+
- **Summary report** - Markdown documentation with previews
51+
52+
Files are saved to:
53+
```
54+
uae_coin_project/
55+
β”œβ”€β”€ qr_codes/
56+
β”‚ β”œβ”€β”€ emirate1_abudhabi_qr.png
57+
β”‚ β”œβ”€β”€ emirate1_abudhabi_qr.svg
58+
β”‚ β”œβ”€β”€ emirate2_dubai_qr.png
59+
β”‚ β”œβ”€β”€ emirate2_dubai_qr.svg
60+
β”‚ β”œβ”€β”€ falcon_eye_culture_qr.png
61+
β”‚ β”œβ”€β”€ falcon_eye_culture_qr.svg
62+
β”‚ β”œβ”€β”€ project_webpage_qr.png
63+
β”‚ β”œβ”€β”€ project_webpage_qr.svg
64+
β”‚ β”œβ”€β”€ documentation_qr.png
65+
β”‚ β”œβ”€β”€ documentation_qr.svg
66+
β”‚ β”œβ”€β”€ downloadable_3d_model_qr.png
67+
β”‚ └── downloadable_3d_model_qr.svg
68+
└── docs/
69+
└── QR_CODES_SUMMARY.md
70+
```
71+
72+
## πŸ“– Documentation
73+
74+
- **[QR Codes Summary](docs/QR_CODES_SUMMARY.md)** - Overview of all generated QR codes with previews
75+
- **[Update Instructions](docs/UPDATE_QR_DESTINATIONS.md)** - Guide for updating QR code destinations
76+
77+
## πŸ”§ Customization
78+
79+
### Updating URLs
80+
81+
Edit `generate_qr_codes.py` and modify the `QR_DESTINATIONS` dictionary:
82+
83+
```python
84+
QR_DESTINATIONS = {
85+
'emirate1_abudhabi': {
86+
'url': 'https://u.ae/abudhabi', # Change this URL
87+
'description': 'Emirate 1 (Abu Dhabi) - Live at minting',
88+
'filename': 'emirate1_abudhabi_qr'
89+
},
90+
# ... more entries
91+
}
92+
```
93+
94+
Then regenerate:
95+
```bash
96+
python generate_qr_codes.py
97+
```
98+
99+
### Adjusting QR Code Appearance
100+
101+
Modify parameters in the generator methods:
102+
103+
```python
104+
# For PNG
105+
generator.generate_qr_png(url, filename, box_size=10, border=4)
106+
107+
# For SVG
108+
generator.generate_qr_svg(url, filename, box_size='10mm', border=4)
109+
```
110+
111+
## πŸ’‘ Usage Examples
112+
113+
### Embedding in HTML
114+
115+
```html
116+
<!-- Using PNG -->
117+
<img src="qr_codes/emirate1_abudhabi_qr.png" alt="Abu Dhabi QR Code" width="200">
118+
119+
<!-- Using SVG (recommended for web) -->
120+
<img src="qr_codes/emirate1_abudhabi_qr.svg" alt="Abu Dhabi QR Code" width="200">
121+
```
122+
123+
### Embedding in Markdown
124+
125+
```markdown
126+
![Abu Dhabi QR Code](qr_codes/emirate1_abudhabi_qr.png)
127+
```
128+
129+
### Embedding in LaTeX/PDF Documents
130+
131+
```latex
132+
\includegraphics[width=3cm]{qr_codes/emirate1_abudhabi_qr.png}
133+
```
134+
135+
### Using in Python
136+
137+
```python
138+
from generate_qr_codes import UAECoinQRGenerator
139+
140+
# Create generator
141+
generator = UAECoinQRGenerator(output_dir='my_qr_codes')
142+
143+
# Generate a single QR code
144+
generator.generate_qr_png('https://example.com', 'my_qr_code')
145+
146+
# Generate all QR codes
147+
results = generator.generate_all_qr_codes()
148+
```
149+
150+
## βœ… Best Practices
151+
152+
### For Print Materials
153+
- Use PNG format at 300+ DPI
154+
- Ensure minimum size of 2cm x 2cm for reliable scanning
155+
- Test print quality before mass production
156+
- Maintain white border (quiet zone) of at least 4 modules
157+
158+
### For Digital Display
159+
- Use SVG format for scalability
160+
- Ensure responsive design on mobile devices
161+
- Test on multiple screen sizes
162+
- Provide fallback link text below QR code
163+
164+
### For Physical Coins
165+
- Consider surface finish and scanning conditions
166+
- Test under various lighting conditions
167+
- Use high error correction (already enabled)
168+
- Position QR code on flat surface area
169+
170+
## πŸ”’ Security Considerations
171+
172+
- All URLs use HTTPS for secure connections
173+
- High error correction (30%) enables scanning even with minor damage
174+
- URLs are publicly accessible (no authentication required)
175+
- No personal or sensitive information encoded in QR codes
176+
177+
## πŸ§ͺ Testing
178+
179+
Validate QR code generation:
180+
181+
```bash
182+
# Run the generator and verify output
183+
python generate_qr_codes.py
184+
185+
# Check that all files were created
186+
ls -la qr_codes/
187+
188+
# Verify the summary report was generated
189+
cat docs/QR_CODES_SUMMARY.md
190+
```
191+
192+
Test QR codes:
193+
1. Scan each QR code with multiple smartphones
194+
2. Test on both iOS and Android devices
195+
3. Verify destination URLs load correctly
196+
4. Check mobile responsiveness of destination pages
197+
198+
## πŸ“Š Technical Specifications
199+
200+
- **Error Correction**: Level H (High) - 30% recovery
201+
- **QR Code Version**: Auto-adjusted based on data length
202+
- **Box Size**: 10px (PNG) / 10mm (SVG)
203+
- **Border**: 4 modules (standard quiet zone)
204+
- **Color Scheme**: Black on white for maximum contrast
205+
- **Image Formats**: PNG (raster) and SVG (vector)
206+
207+
## πŸ”„ Post-Deployment Updates
208+
209+
After QR codes are deployed (printed/embedded):
210+
211+
1. **URL Redirects**: Use redirects to change destinations without regenerating QR codes
212+
2. **Content Updates**: Update content at destination URLs
213+
3. **Analytics**: Monitor QR code scans using URL tracking
214+
215+
See [UPDATE_QR_DESTINATIONS.md](docs/UPDATE_QR_DESTINATIONS.md) for detailed instructions.
216+
217+
## πŸ“ License
218+
219+
This QR code generation system is part of the Activbot project.
220+
See the main [LICENSE](../LICENSE) file for details.
221+
222+
## 🀝 Contributing
223+
224+
To add new QR codes or improve the system:
225+
226+
1. Edit `generate_qr_codes.py`
227+
2. Add new entries to `QR_DESTINATIONS`
228+
3. Regenerate QR codes
229+
4. Update documentation
230+
5. Submit a pull request
231+
232+
## πŸ“ž Support
233+
234+
For issues or questions:
235+
- GitHub Issues: https://github.com/ELMOURABEA/Activbot/issues
236+
- Documentation: See main README.md
237+
238+
---
239+
240+
**Generated by Activbot QR Code System** πŸ‡¦πŸ‡ͺ

0 commit comments

Comments
Β (0)